package com.lhz.config;

import io.swagger.v3.oas.models.OpenAPI;
import io.swagger.v3.oas.models.info.Info;
import io.swagger.v3.oas.models.info.License;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @Author: LiHuaZhi
 * @Date: 2020/8/22 16:06
 * @Description:
 **/
@Configuration
public class SwaggerConfiguration {

    @Bean("task-service")
    public OpenAPI customOpenAPI() {
        return new OpenAPI()
                .info(new Info()
                        .title("task-service")
                        .version("1.0")
                        .description("task-service接口文档")
                        .termsOfService("http://www.lhz.com")
                        .license(new License().name("Apache 2.0")));
    }
}